From: Carlos Garnacho Date: Tue, 16 Mar 2021 20:44:54 +0000 (+0100) Subject: hotplug-sniffer: Drop "volatile" from g_once_init_enter() sentinels X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~616^2^2~93 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=4dfc53cade812e3b63205620fa13e31955e72763;p=gnome-shell.git hotplug-sniffer: Drop "volatile" from g_once_init_enter() sentinels As documented in g_once_init_enter(): "While @location has a volatile qualifier, this is a historical artifact and the pointer passed to it should not be volatile.". And effectively this now warns with modern glibc. Drop this from our logging function. Part-of: --- diff --git a/src/hotplug-sniffer/hotplug-sniffer.c b/src/hotplug-sniffer/hotplug-sniffer.c index 7fd812ea0..4b70ec72a 100644 --- a/src/hotplug-sniffer/hotplug-sniffer.c +++ b/src/hotplug-sniffer/hotplug-sniffer.c @@ -269,7 +269,7 @@ print_debug (const gchar *format, ...) g_autofree char *timestamp = NULL; va_list ap; g_autoptr (GDateTime) now = NULL; - static volatile gsize once_init_value = 0; + static size_t once_init_value = 0; static gboolean show_debug = FALSE; static guint pid = 0;